Gun (simplified Chinese: 鲧; traditional Chinese: 鯀; pinyin: gǔn, and Gwan2 in jyutping) was the father of Yu the Great, the founder of the Xia Dynasty. He was appointed by Yao to control the flooding rivers. He used dikes to stop the rivers from flooding, but they eventually collapsed after nine years and killed many people.
In many versions of the mythology, Gun seems to be a half-god like character. In legends he even discovers some of the secrets of the Gods. To make the dikes, which can stop the rising water, he stole the XiRang (Earth which can reproduce itself) of the Gods. After the dikes were finished, when the water levels rose, the magical earth of the dike also rose to keep the water out. It worked very well at the first, but when the dikes rose too high (In the legend, it was nine Ren, an ancient Chinese measure of length) they collapsed, resulting in the death of many people in the subsequent flood. Some legends say that Gun was executed by Shun, and others say that he committed suicide. Before his death he told his son, Yu the Great, to finish his job.